package com.ruoyi.system.service.impl;

import java.util.List;

import com.ruoyi.common.core.utils.DateUtils;
import com.ruoyi.system.api.domain.SchoolPayrecordd;
import com.ruoyi.system.mapper.SchoolPayrecorddMapper;
import com.ruoyi.system.service.ISchoolPayrecorddService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 缴费记录明细Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-02-09
 */
@Service
public class SchoolPayrecorddServiceImpl implements ISchoolPayrecorddService
{
    @Autowired
    private SchoolPayrecorddMapper schoolPayrecorddMapper;

    /**
     * 查询缴费记录明细
     * 
     * @param id 缴费记录明细ID
     * @return 缴费记录明细
     */
    @Override
    public SchoolPayrecordd selectSchoolPayrecorddById(Long id)
    {
        return schoolPayrecorddMapper.selectSchoolPayrecorddById(id);
    }

    /**
     * 查询缴费记录明细列表
     * 
     * @param schoolPayrecordd 缴费记录明细
     * @return 缴费记录明细
     */
    @Override
    public List<SchoolPayrecordd> selectSchoolPayrecorddList(SchoolPayrecordd schoolPayrecordd)
    {
        return schoolPayrecorddMapper.selectSchoolPayrecorddList(schoolPayrecordd);
    }

    /**
     * 新增缴费记录明细
     * 
     * @param schoolPayrecordd 缴费记录明细
     * @return 结果
     */
    @Override
    public int insertSchoolPayrecordd(SchoolPayrecordd schoolPayrecordd)
    {
        schoolPayrecordd.setCreateTime(DateUtils.getNowDate());
        return schoolPayrecorddMapper.insertSchoolPayrecordd(schoolPayrecordd);
    }

    /**
     * 修改缴费记录明细
     * 
     * @param schoolPayrecordd 缴费记录明细
     * @return 结果
     */
    @Override
    public int updateSchoolPayrecordd(SchoolPayrecordd schoolPayrecordd)
    {
        return schoolPayrecorddMapper.updateSchoolPayrecordd(schoolPayrecordd);
    }

    /**
     * 批量删除缴费记录明细
     * 
     * @param ids 需要删除的缴费记录明细ID
     * @return 结果
     */
    @Override
    public int deleteSchoolPayrecorddByIds(Long[] ids)
    {
        return schoolPayrecorddMapper.deleteSchoolPayrecorddByIds(ids);
    }

    /**
     * 删除缴费记录明细信息
     * 
     * @param id 缴费记录明细ID
     * @return 结果
     */
    @Override
    public int deleteSchoolPayrecorddById(Long id)
    {
        return schoolPayrecorddMapper.deleteSchoolPayrecorddById(id);
    }
}
